package freedom.ms.api.controller;

import java.text.MessageFormat;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

@Controller
public class HomeController {
	@Value("${spring.application.name}")
	String name;
	@Value("${server.port}")
	String port;

	@RequestMapping({"/inf"})
	@ResponseBody
	public String info() {
		return MessageFormat.format("{0} {1}", name, port);
	}
	@RequestMapping({"/index"})
	public String index() {
		return "index";
	}
	
}
